import { createApp } from 'vue'
import App from './App.vue'
import router from '@/router'
import store from '@/store'
import api from './api' // 导入api接口
// 全局导入vant组件，会增加项目包体积
import Vant from 'vant'
import { Dialog } from 'vant';
import 'vant/lib/index.css'
// import Video from 'video.js'
// import 'video.js/dist/video-js.css'

import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
const app = createApp(App)
app.api = api
app.use(router)
  .use(store)
  .use(api)
  .use(Vant)
  .use(ElementPlus)

app.mount('#app')
app.config.globalProperties.$axios = api
 
// import {
//   ElButton, ElTable, ElTableColumn
// } from 'element-plus'
// import lang from 'element-plus/lib/locale/lang/zh-cn'
// import locale from 'element-plus/lib/locale'
// app.use(Button)
// export default (app) => {
//   locale.use(lang)
//   app.use(ElButton.name)// 注册element组件
//   app.use(ElTable)
//   app.use(ElButton)
//   app.use(ElTableColumn)
// }
